package pojo;

import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

public class User {

	private String id;
	private String uname;
	private boolean sex;
	private double sal;
	private Integer age;
	@DateTimeFormat(pattern="yyyy-MM-dd")
	private Date birth;

	public User() {
	}

	public User(String id, String uname, boolean sex, double sal, Integer age, Date birth) {
		this.id = id;
		this.uname = uname;
		this.sex = sex;
		this.sal = sal;
		this.age = age;
		this.birth = birth;
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getUname() {
		return uname;
	}

	public void setUname(String uname) {
		this.uname = uname;
	}

	public boolean getSex() {
		return sex;
	}

	public void setSex(boolean sex) {
		this.sex = sex;
	}

	public double getSal() {
		return sal;
	}

	public void setSal(double sal) {
		this.sal = sal;
	}

	public Integer getAge() {
		return age;
	}

	public void setAge(Integer age) {
		this.age = age;
	}

	public Date getBirth() {
		return birth;
	}

	public void setBirth(Date birth) {
		this.birth = birth;
	}

	@Override
	public String toString() {
		return "User{" +
				"id='" + id + '\'' +
				", uname='" + uname + '\'' +
				", sex=" + sex +
				", sal=" + sal +
				", age=" + age +
				", birth=" + birth +
				'}';
	}
}
